package me.keiwu.pub.data;

import lombok.Getter;

/**
 * Created by kei on 09/11/2017.
 */
public enum LockKeyEnum {

    /**
     * 购买形象的锁
     */
    BUY_AVATAR("LOCK_KEY_BUY_AVATAR"),

    /**
     * 改变星币的锁
     */
    CHANGE_GOLD("LOCK_KEY_CHANGE_GOLD"),

    /**
     * 更新总步数
     */
    UPDATE_USER_TOTAL_STEP("LOCK_UPDATE_USER_TOTAL_STEP"),

    /**
     * 更新总捐步数
     */
    UPDATE_TOTAL_DONATE_STEP("LOCK_UPDATE_TOTAL_DONATE_STEP"),
    ;


    @Getter
    private String prefix;


    LockKeyEnum(String prefix) {
        this.prefix = prefix;
    }


    public String getLockKey(String key) {
        return this.prefix + key;
    }

    public String getLockKey(long key) {
        return this.prefix + key;
    }


}
